package pokerAI.PokerAI;
import java.io.*;
import java.util.Arrays;
import java.util.ArrayList;
import java.util.Stack;
import java.util.Random;
import java.lang.Math;
import java.lang.String;


public class BigHand{
    private Card[] cards;
    int count;                              // amount of cards in hand

    
    public BigHand(){
            cards = new Card[7];
            count = 0;
    }
    public BigHand(Card[] c)
    {
            cards = new Card[5];
            for(int i=0; i<5; i++)
            {
                    cards[i] = new Card(c[i].getNumber(), c[i].getSuit());
            }
    
    }
    
    public void receiveCard( Card c ){
            if ( count < 7 ){
                    cards[count] = c;
                    count++;
            }
    }

    
    public Card viewCard( int i ){
            Card c = new Card();
            if (i < count){
                    c = cards[i];
            }
            // if they are requestion a card that they do not own
            // let them know and then give them the topmost card they have
            else{
                    System.out.println("That Card does not exist, top card is");
                    c = cards[count-1];
            }
            return c;
    }       
            
    public void setCard( int i, Card c ){
            cards[i] = c;
    }
    
    public int getAmountOfCards(){
            return count;
    }
    
    public boolean isHandEmpty(){
            boolean b = false;
            if (count == 0){
                    b = true;
            }
            return b;
    }
    
}

